extends basic

block extra_head
    <title>ECharts Documentation</title>
    style.
        html, body {
            /* position: sticky should not have overflow parents.*/
            overflow-x: hidden;
        }
    link(rel="stylesheet", href="#{cdnRoot}/#{ecWWWLang}/css/doc-bundle.css?_v_=#{homeVersion}")

block content

    nav(class='navbar navbar-default navbar-fixed-top doc-nav' id="ec-doc-nav")
        if ecWWWLang == 'en'
            include ../en/nav
        else
            include ../components/nav

    block vars

    if isOption
        .doc-version-change
            if ecWWWLang == 'zh'
                if isECharts4
                    a(href="option3.html") 前往 v3.x 文档
                else
                    a(href="option.html") 前往 v4.x 文档
                a(href="https://www.echartsjs.com/echarts2/") 前往 v2.x 文档
            else
                if isECharts4
                    //- a(href="option3.html") v3.x Doc
                else
                    a(href="option.html") v4.x Doc
                a(href="https://www.echartsjs.com/echarts2/index-en.html") v2.x Doc


    #ec-doc-main

block extra_js
    script(src="#{cdnRoot}/#{ecWWWLang}/js/doc-bundle.js?_v_=#{homeVersion}")
    script(type="text/javascript").
        window.EC_WWW_CDN_ROOT = '#{cdnRoot}';

    block global_args_extra

    script(type="text/javascript").
        document.getElementById('nav-doc').className = 'active';
        window.globalArgsExtra.version = '#{homeVersion}';
        echartsDoc.init('#ec-doc-main', window.globalArgsExtra);

